package dr.branch.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import dr.branch.dao.BranchDAO;
import dr.controller.Action;


public class ConfirmCodeAction implements Action {

	@Override
	public String execute(HttpServletRequest request,
			HttpServletResponse response) throws Throwable {
		
		int b_code = Integer.parseInt((request.getParameter("b_code")));
		BranchDAO dbPro = BranchDAO.getInstance();
		int check = dbPro.confirmCode(b_code);
		
		request.setAttribute("check",new Integer(check));
			request.setAttribute("b_code", b_code);
			
		return "/branch/confirmCode.jsp";
	}

}
